class Dog:
    def __init__(self, name, color):
        self.name = name
        self.color = color

        def jiao(self):
            print("看见生人汪汪叫")


        def yao(self):
            print("看见熟人摇尾巴")


dog1 = Dog("大黄", "黄色")
dog1.jiao()
dog1.yao()